<?php get_header(); ?>

<div id="main-area-wrap">
	<div id="wrapper">
		<div id="main">
			<div class="post">
<?php if (get_option('glow_integration_single_top') <> '' && get_option('glow_integrate_singletop_enable') == 'on') echo(get_option('glow_integration_single_top')); ?>	
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
			<div class="new-post">
				<?php if (get_option('glow_postinfo_posts') == 'on') include(TEMPLATEPATH . '/includes/postinfo.php'); ?>
				<h1><?php the_title(); ?></h1>
				<div id="post-content"> 
<?php if (get_option('glow_thumbnails') == 'on') { ?>
<?php $thumb = get_post_meta($post->ID, 'Thumbnail', $single = true); ?>
<?php if (($thumb == '') && ($glow_grab_image == 'on')) $thumb = catch_that_image(); ?>
	<?php if($thumb !== '') { ?>
					<img src="<?php bloginfo('stylesheet_directory'); ?>/timthumb.php?src=<?php echo $thumb; ?>&amp;h=<?php echo(get_option('glow_thumbnail_height_posts')); ?>&amp;w=<?php echo(get_option('glow_thumbnail_width_posts')); ?>&amp;zc=1" alt="<?php echo the_title(); ?>" class="thumbnail alignleft" width="<?php echo(get_option('glow_thumbnail_width_posts')); ?>" height="<?php echo(get_option('glow_thumbnail_height_posts')); ?>px" />
		<?php };}; ?>
					<?php the_content(); ?>
					<?php edit_post_link('Edit this post'); ?>
					
				</div> <!-- end #post-content -->	
			</div> <!-- end new-post -->	
			
			
			<?php if (get_option('glow_integration_single_bottom') <> '' && get_option('glow_integrate_singlebottom_enable') == 'on') echo(get_option('glow_integration_single_bottom')); ?>		
            <?php if (get_option('glow_468_enable') == 'on') { ?>
				<a href="<?php echo(get_option('glow_468_url')); ?>"><img src="<?php echo(get_option('glow_468_image')); ?>" alt="468 ad" class="foursixeight" /></a>
			
            <?php } ?>
            
			<?php if (get_option('glow_show_postcomments') == 'on') comments_template('', true); ?>
            
<?php endwhile; ?>

<?php else : ?>
	<!--If no results are found-->
	<div id="post-content"> 
		<h1>No Results Found</h1>
		<p>The page you requested could not be found. Try refining your search, or use the navigation above to locate the post.</p>
	</div>
	<!--End if no results are found-->
<?php endif; ?>
			</div> <!-- end post -->
		</div> <!-- end main -->
<?php get_sidebar(); ?>
<?php get_footer(); ?>